home *** CD-ROM | disk | FTP | other *** search
/ Windows Game Programming for Dummies (2nd Edition) / WinGamProgFD.iso / pc / DirectX SDK / DXSDK / samples / Multimedia / DirectShow / Players / Jukebox / Jukebox.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  2001-10-09  |  2.2 KB  |  74 lines

  1. //------------------------------------------------------------------------------
  2. // File: Jukebox.cpp
  3. //
  4. // Desc: DirectShow sample code - an MFC based C++ jukebox application.
  5. //
  6. // Copyright (c) 1998-2001 Microsoft Corporation.  All rights reserved.
  7. //------------------------------------------------------------------------------
  8.  
  9.  
  10. #include "stdafx.h"
  11. #include "Jukebox.h"
  12. #include "JukeboxDlg.h"
  13.  
  14. #ifdef _DEBUG
  15. #define new DEBUG_NEW
  16. #undef THIS_FILE
  17. static char THIS_FILE[] = __FILE__;
  18. #endif
  19.  
  20. /////////////////////////////////////////////////////////////////////////////
  21. // CJukeboxApp
  22.  
  23. BEGIN_MESSAGE_MAP(CJukeboxApp, CWinApp)
  24.     //{{AFX_MSG_MAP(CJukeboxApp)
  25.         // NOTE - the ClassWizard will add and remove mapping macros here.
  26.         //    DO NOT EDIT what you see in these blocks of generated code!
  27.     //}}AFX_MSG
  28.     ON_COMMAND(ID_HELP, CWinApp::OnHelp)
  29. END_MESSAGE_MAP()
  30.  
  31. /////////////////////////////////////////////////////////////////////////////
  32. // CJukeboxApp construction
  33.  
  34. CJukeboxApp::CJukeboxApp()
  35. {
  36.     // TODO: add construction code here,
  37.     // Place all significant initialization in InitInstance
  38. }
  39.  
  40. /////////////////////////////////////////////////////////////////////////////
  41. // The one and only CJukeboxApp object
  42.  
  43. CJukeboxApp theApp;
  44.  
  45. /////////////////////////////////////////////////////////////////////////////
  46. // CJukeboxApp initialization
  47.  
  48. BOOL CJukeboxApp::InitInstance()
  49. {
  50.     // Standard initialization
  51.     // If you are not using these features and wish to reduce the size
  52.     //  of your final executable, you should remove from the following
  53.     //  the specific initialization routines you do not need.
  54.  
  55. #ifdef _AFXDLL
  56.     // In MFC 5.0, Enable3dControls and Enable3dControlsStatic are obsolete because
  57.     // their functionality is incorporated into Microsoft's 32-bit operating systems.
  58. #if (_MSC_VER <= 1200)
  59.     Enable3dControls();            // Call this when using MFC in a shared DLL
  60. #endif
  61. #else
  62.     Enable3dControlsStatic();    // Call this when linking to MFC statically
  63. #endif
  64.  
  65.     CJukeboxDlg dlg;
  66.     m_pMainWnd = &dlg;
  67.  
  68.     dlg.DoModal();
  69.  
  70.     // Since the dialog has been closed, return FALSE so that we exit the
  71.     //  application, rather than start the application's message pump.
  72.     return FALSE;
  73. }
  74.